Macros

Contents|Index|Previous|Next
Macros

A macro is a sort of abbreviation which you can define once and then use later. There are many complicated features associated with macros in the C preprocessor.

See the following documentation for more detailed discussion of macros.

- Simple macros
- Macros with arguments
- Predefined macros

- Standard predefined macros
- Nonstandard predefined macros

- Stringification
- Concatenation
- Undefining macros
- Redefining macros
- Pitfalls and subtleties of macros

- Improperly nested constructs
- Unintended grouping of arithmetic
- Swallowing the semicolon
- Duplication of side effects
- Self-referential macros
- Separate expansion of macro arguments
- Cascaded use of macros
- Newlines in macro arguments

Top|Contents|Index|Previous|Next